<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />



<head>
	<title>Projektseminar</title>
</head>


	<link rel="stylesheet" type="text/css" href="css/jquery-ui-1.8.18.custom.css" />
	<link rel="stylesheet" type="text/css" href="css/main.css" />
	<script src="lib/jquery-1.7.2.js"></script>
	<script src="lib/jquery-ui-1.8.18.custom.min.js"></script>
	<script>
		
			
		function onMouseOverNeu() {
			document.getElementById("buttonstart").className="buttonstartMouseOver";
		};
		function onMouseOutNeu() {
			document.getElementById("buttonstart").className="buttonstart";
		};
			
		function onPlayTitleMusic() {
		document.getElementById('title_music1').play();
		document.getElementById('title_music1').addEventListener('ended', function(){
			this.currentTime = 0;
			this.pause();
			document.getElementById('title_music2').play();
		}, false);
		document.getElementById('title_music2').addEventListener('ended', function(){
			this.currentTime = 0;
			this.pause();
			document.getElementById('title_music1').play();
		}, false); 	

	};
			
		function startGame(){
			console.log("startgame");
			
			document.getElementById('startwindow').className="ei";
			document.getElementById("dodoText").className="dodoText";

            $("#buttonstart").remove();

            setTimeout(function(){
                location = "index.html";
            }, 6000);

		};
	</script>


<body onLoad="javascript:onPlayTitleMusic();">


	<div id ="startwindow" class="title">
		<div id="buttonstart" class="buttonstart" 
			onclick="javascript:startGame();"
			onmouseover="javascript:onMouseOverNeu()"
			onmouseout="javascript:onMouseOutNeu();"></div>	
		
		<div id="dodoText" class="hiddendiv"></div>	
		
		
	
		<audio id="title_music1">
			<source src="./data/sound/comedicJuggernaut.wav">
		</audio>
		<audio id="title_music2">
			<source src="./data/sound/comedicJuggernaut.wav">
		</audio>
		

	</div>
</body>

</html>